<div>
<a href="/admin/new-cup-ko/">创建新淘汰赛</a>
</div>
<div class="table-league-title" >
    <div class="float-left league-id">淘汰赛id</div>
    <div class="float-left league-name">淘汰赛名称</div>
    <div class="float-left league-team-nb">球队数量</div>
	<div class="float-left league-team-nb">比赛类型</div>
    <div class="float-left league-action" style="width : 100px;">操作</div>

</div>

<div class="table-league">
	
<?php foreach($this->cups as $cup){?>
	  <div class="float-left league-id"><?php echo $cup->id?></div>
    <div class="float-left league-name"><?php echo $cup->name?></div>
    <div class="float-left league-team-nb"><?php echo $cup->team_count?></div>
	<div class="float-left league-team-nb"><?php echo $cup->type=='single'?'单循环':'双循环'?></div>
    <div class="float-left league-action" style="width : 100px;">
    	 <?php if ($cup->status =='new'){?>
        	<a href="/admin/cup-ko-team/cup-id/<?php echo $cup->id?>/">修改</a>        	      
        	<a href="/admin/cup-ko-close/cup-id/<?php echo $cup->id?>/" 
        	onclick="return confirm('确认结束杯赛淘汰赛 : <?php echo $cup->name;?> ？\n结束后玩家将不再可以录入比分');">结束</a>
        <?php }?>
        </div>
<?php }?>
</div>